'''
Created on May 12, 2011

@author: oabalbin
'''
def read_file(input_file_name,out_file_name):
    '''
    if the number line is in the array of randomly generated
    integers print the lines otherwise skkip it    
    '''
    input_file = open(input_file_name)
    outfile=open(out_file_name,'w')
    i=0
    print 'Randomizing %s'%(input_file_name)
    for l in input_file:
        if l.startswith('#'):
            outfile.write(l)
            continue
        if i < 10:
            print l
            print l.strip('\n').split('\t')[:10]
        i+=1
        
    outfile.close()

input_file_name='/exds/projects/alignment_indexes/gatk/hg19/hapmap3.3.genotypes.b37_fwd_process_tab2_random.vcf'
out_file_name='/exds/projects/alignment_indexes/gatk/hg19/hapmap3.3.genotypes.b37_fwd_process_tab2_random.vcf_test'

read_file(input_file_name,out_file_name)
